﻿using System.Windows;
using System.Windows.Controls;
using System.Windows.Media;
using CrateMayhem.Common.Controls;
using CrateMayhem.Desktop.Common;

namespace CrateMayhem.Desktop.Controls
{
    public class Brick : Border, IBrick
    {
        private static readonly Brush brush;
        private static readonly Brush borderBrush;

        public Brick()
        {
            DefaultStyleKey = typeof (Brick);
            CornerRadius = new CornerRadius(2);
            BorderThickness = new Thickness(1);
            Background = brush;
            BorderBrush = borderBrush;
        }

        static Brick()
        {
            brush = Common.Resources.GameStyles.Get<Brush>("BrickBackgroundBrush");
            borderBrush = Common.Resources.GameStyles.Get<Brush>("BrickBorderBrush");
        }
    }
}